<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>
<body>
  <div id="app"></div>

  <script src="../packages/runtime-dom/dist//runtime-dom.global.js"></script>

  <script>

    const { createApp, h, reactive } = VueRuntimeDom;

    const app = {
      setup() {
        const state = reactive({
          name: 'hello'
        })

        const onClick = (e) => {
          state.name = 'nihao'
          state.name = 'beijing'
        }

        return () => {
          return h('div', { style: { color: 'red'}, onClick }, state.name);
        }
      }
    }

    createApp(app, { name: 'huwei' }).mount('#app');

  </script>  
</body>
</html>